package io.renren.modules.sp.service;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import io.renren.common.page.PageData;
import io.renren.common.service.CrudService;
import io.renren.common.utils.Result;
import io.renren.modules.sp.dto.SpUserDTO;
import io.renren.modules.sp.entity.SpUserEntity;

import javax.servlet.http.HttpServletResponse;
import java.util.List;
import java.util.Map;

/**
 * 用户
 *
 * @author whc 15953295779@126.com
 * @since 3.0 2023-04-21
 */
public interface SpUserService extends CrudService<SpUserEntity, SpUserDTO> {

    List<SpUserEntity> queryList(QueryWrapper<SpUserEntity> params);
    /**
     * 检查信息
     * */
    String checkInfo(SpUserDTO user);

    Map<String,Object> queryUserById(Long userId);

    Result<SpUserEntity> queryUser(SpUserDTO loginInfo);

    Result<String> updateUserType(String phone, String roleId);

    Result<String> upgradeTeacher(Long userId, String password);

    Result<String> addTeacherUserType(Long userId, String password);
}
